/*
 * Copyright© 2003-2019 浙江汇信科技有限公司, All Rights Reserved.
 */
package com.icinfo.cloud.provider.punish.service;

import com.icinfo.cloud.provider.common.constant.PunishMainServicePortUriConstant;
import com.icinfo.cloud.provider.common.dto.SendDocumentDto;
import com.icinfo.cloud.provider.common.utils.PunishMainClientUtil;
import com.icinfo.cloud.provider.punish.common.documentoperate.dto.StageDocCommonHtmlRequest;
import com.icinfo.cloud.provider.punish.common.documentoperate.dto.StageDocCommonOperateSaveDto;
import com.icinfo.cloud.provider.punish.common.documentoperate.vo.DocumentCommonFormHtmlVo;
import com.icinfo.cloud.provider.punish.common.electricsent.dto.*;
import com.icinfo.cloud.provider.punish.common.electricsent.vo.CaseDocumentSendinfoConfirmVo;
import com.icinfo.cloud.provider.punish.dto.*;
import com.icinfo.cloud.provider.punish.vo.*;
import com.icinfo.framework.common.web.Result;
import com.icinfo.framework.core.service.BaseService;
import io.swagger.annotations.ApiOperation;
import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;

import java.util.List;

/**
 * 描述: 文书发送记录 document_send_record 对应的Service接口.<br>
 *
 * @author framework generator
 * @date 2022年03月30日
 */
public interface IDocumentSendRecordService extends BaseService {

    /**
     * 获取待发送文书记录数量
     * @author  lxj
     * @param  userId
     * @return int
     */
    int countWaitSendDocument(String userId);

    /**获取送达文书记录
     * @author  lxj
     * @param documentSendDto
     * @return list
     */
    List<SendTaskVo> getDocumentSendList(DocumentSendDto documentSendDto);


    /**
     * 生成签字捺印文书
     * @author   lxj
     * @param appDocumentSignSaveDto
     * @return  String
     */
    String submitSendFingerAndSign(AppDocumentSignSaveDto appDocumentSignSaveDto);

    /**
     * 获取文书详情
     * @param documentId
     * @author   lxj
     * @return
     */
    String getDocSentDetail(String documentId);

    /**
     * 获取送达回证文书内容
     * @param request
     * @author   lxj
     * @return DocumentCommonFormHtmlVo
     */
    DocumentCommonFormHtmlVo getDocumentFormHtml(StageDocCommonHtmlRequest request);

    /**
     * 获取文书抬头
     * @return
     */
    String getStandOrgName();

    /**
     * 委托事项获取文书抬头
     * @return
     */
    String getStandOrgNameByCondition(String orgCode,String deptCode);

    /**
     * 描述：生成送达回证文书
     *
     * @param dto {@link StageDocCommonOperateSaveDto} 送达回证文书内容
     * @return 送达回证文书地址
     * @author xiangyuyu
     * @date 2022-06-27 16:00
     */
    String generateSentReceiptDoc(StageDocCommonOperateSaveDto dto);


    /**
     * 描述： 确认送达(电子送达)
     *
     * @author: zhengqiang
     * @date: 2022/7/4
     * @param: saveDto
     * @return {@link Result< String>}
     **/
    Result<String> confirmSend(ConfirmSendSaveDto saveDto);




    /**
     * 描述：【V1.3.2】描述：现场送达状态标记
     *
     * @param saveDto {@link RealPlaceSentInfoSaveDto}
     * @return Result<String> 操作结果
     * @author xiangyuyu
     * @date 2022/8/5
     * @since 1.3.2
     */
    Result<String> signRealPlaceSentInfo(RealPlaceSentInfoSaveDto saveDto);


    /**
     * 描述：【V1.3.2】保存文书送达登记
     *
     * @param saveDto {@link DocumentSentRegisterSaveDto}
     * @return {@link Result <String>} 保存结果
     * @author xiangyuyu
     * @date 2022/8/5
     * @since 1.3.2
     */
    Result<String> saveDocumentSentRegister(DocumentSentRegisterSaveDto saveDto);

    /**
     * 描述： 根据当事人证件号及部门获取电子送达页面送达人初始化信息
     *
     * @author: zhengqiang
     * @date: 2022/6/30
     * @param: request
     * @return {@link CaseDocumentSendinfoConfirmVo}
     **/
    CaseDocumentSendinfoConfirmVo getCaseDocumentSendInfoConfirmInfo(DocumentSentAddressInfoRequest request);


    /**
     * 描述：获取送达详情
     *
     * @param dto {@link DocumentSentFlowDetailInfoDto}
     * @return {@link Result< AppDocumentSentFlowDetailInfoVo >}
     * @author xiangyuyu
     * @date 2022/8/8
     * @since 1.3.2
     */
    AppDocumentSentFlowDetailInfoVo getDocumentSentFlowDetailInfo(DocumentSentFlowDetailInfoDto dto);


    /**
     * 【V1.3.2】描述：保存签字捺印文书信息
     *
     * @param saveDto {@link AppDocumentSignAssembleInfoDto}
     * @return {@link Result<String>} 操作结果
     * @author xiangyuyu
     * @date 2022/8/8
     * @since 1.3.2
     */
    Result<String> saveDocumentSignInfo(AppDocumentSignAssembleInfoDto saveDto);

    /**
     * 【V1.3.2】描述：获取送达表单信息
     *
     * @param dto {@link SentFormInfoDto}
     * @return {@link Result< SentFormInfoVo >} 送达表单信息
     * @author xiangyuyu
     * @date 2022/8/8
     * @since 1.3.2
     */
    SentFormInfoVo getSentFormInfo(SentFormInfoDto dto);

    /**
     * 【V1.3.2】描述： 获取多当事人文书送达详情
     *
     * @author: zhengqiang
     * @date: 2022/8/11
     * @param: queryDto
     * @return {@link CasePartiesDocSendInfoVo}
     **/
    CasePartiesDocSendInfoVo getPartiesDocSendInfo(DocumentSendRecordByPartiesQueryDto queryDto);

    /**
     * 描述： 发送文书短信
     *
     * @author: zhengqiang
     * @date: 2022/8/28
     * @param: smsDto
     * @return {@link Result< String>}
     **/
    Result<String> sendDocumentSms(SendDocumentSmsDto smsDto);

    /**
     * 根据签字的文书id来做业务
     *
     * @param saveDto
     * @return
     */
    Result<String> saveDocumentSignIdInfo(AppDocumentSignFileAssembleInfoDto saveDto);
}
